/**
 * 作者 ：食草狂魔
 *
 * 日期 ：2017/11/29
 *
 * 描述 ：状态树模块-目录管理
 */

export default {
  state: {
    pages: {
      // 模块主页
      main: {
        resourceName: "",
        resourceCode: "",
        departmentId: "",
        status: "",
        createTimeToStart: "",
        createTimeToEnd: ""
      }
    }
  },
  mutations: {
    reloadTableParams (state, obj) {
      state.pages.main.resourceName = obj.resourceName
      state.pages.main.resourceCode = obj.resourceCode
      state.pages.main.departmentId = obj.departmentId
      state.pages.main.status = obj.status
      state.pages.main.createTimeToStart = obj.createTimeToStart
      state.pages.main.createTimeToEnd = obj.createTimeToEnd
    },
  },
  actions: {
    searchTable ({ state, commit, rootState }, obj) {
      commit('reloadTableParams', obj)
    }
  }
}
